package main

import (
	"fmt"
	"net"
)

func main() {
	dial, _ := net.Dial("tcp4", "0.0.0.0:8999")
	for i := 0; i < 10; i++ {
		dial.Write([]byte("消息1"))
		var buf = make([]byte, 512)
		dial.Read(buf)
		fmt.Println(string(buf))
	}
	dial.Close()
}
